package com.xbongbong.crm.service.permission;

import com.xbongbong.paas.domain.entity.ext.PaasFormDataEntityExt;
import com.xbongbong.paas.domain.entity.ext.PaasFormEntityExt;
import com.xbongbong.paas.toolbox.exception.XbbException;
import com.xbongbong.paas.toolbox.wrap.UserVO;
import com.xbongbong.parent.abstracts.AbstractBusinessPermissionService;
import com.xbongbong.saas.enums.XbbRefTypeEnum;
import com.xbongbong.saas.model.CommunicatePlanUserModel;
import com.xbongbong.sys.model.UserModel;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Collections;
import java.util.List;

/**
 * @author sunshaoxiang
 * @ClassName CustomerCommunicatePermissionServiceImpl
 * @Description 跟进记录权限 Service
 * @Date 2022/6/23 10:54
 * @Version 1.0
 **/
@Service
public class CustomerCommunicatePermissionServiceImpl extends AbstractBusinessPermissionService<PaasFormDataEntityExt, PaasFormEntityExt> {
    @Resource
    private UserModel userModel;
    @Resource
    private CommunicatePlanUserModel communicatePlanUserModel;

    @Override
    public List<Integer> businessType() {
        return Collections.singletonList(XbbRefTypeEnum.CUSTOMER_COMMUNICATE.getCode());
    }

    @Override
    public void checkPermission(PaasFormEntityExt formEntity, PaasFormDataEntityExt paasFormDataEntityExt, UserVO loginUser, Integer subBusinessType) throws XbbException {

    }

    @Override
    public boolean hasPermission(PaasFormEntityExt formEntity, PaasFormDataEntityExt paasFormDataEntityExt, UserVO loginUser, Integer subBusinessType) throws XbbException {
        return true;
    }
}
